package com.sa.token.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Builder;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.util.Date;

import static com.baomidou.mybatisplus.annotation.FieldFill.INSERT;

/**
 * <p>
 * 用户角色关联表
 * </p>
 *
 * @author xhs
 * @since 2021-08-27
 */
@Data
@Builder
@EqualsAndHashCode(callSuper = false)
@TableName(value = "sys_user_role", autoResultMap = true)
public class SysUserRoleEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 用户Id
     */
    @TableField("user_id")
    private Integer userId;

    /**
     * 角色Id
     */
    @TableField("role_id")
    private Integer roleId;

    /**
     * 创建日期
     */
    @TableField(value = "create_time", fill = INSERT)
    private Date createTime;


}
